package cn.cs.client;

import cn.cs.config.CsConfiguration;
import cn.cs.fallback.AgentCapitalPoolTypeFallBack;
import cn.cs.pojo.CapitalPoolType;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * Created by yuexl
 */
@FeignClient(name = "cs-agent-provider", configuration = CsConfiguration.class, fallback = AgentCapitalPoolTypeFallBack.class)
public interface AgentCapitalPoolTypeClient {


    @RequestMapping(value = "/getCapitalPoolTypeById", method = RequestMethod.POST)
    public CapitalPoolType getCapitalPoolTypeById(@RequestParam("id") String id) throws Exception;

    @RequestMapping(value = "/getCapitalPoolTypeListByMap", method = RequestMethod.POST)
    public List<CapitalPoolType> getCapitalPoolTypeListByMap(@RequestBody Map<String, Object> param) throws Exception;

    @RequestMapping(value = "/getCapitalPoolTypeCountByMap", method = RequestMethod.POST)
    public Integer getCapitalPoolTypeCountByMap(@RequestBody Map<String, Object> param) throws Exception;

    @RequestMapping(value = "/addCapitalPoolType", method = RequestMethod.POST)
    public Integer addCapitalPoolType(@RequestBody CapitalPoolType capitalPoolType) throws Exception;

    @RequestMapping(value = "/modifyCapitalPoolType", method = RequestMethod.POST)
    public Integer modifyCapitalPoolType(@RequestBody CapitalPoolType capitalPoolType) throws Exception;

    @RequestMapping(value = "/deleteCapitalPoolTypeById", method = RequestMethod.POST)
    public Integer deleteCapitalPoolTypeById(@RequestParam("id") String id) throws Exception;

}

